<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<!DOCTYPE html>
<html lang="zh-CN">
	<head> 
    <meta charset="UTF-8">
    <%@ include file="/WEB-INF/views/include/head.jsp"%>
    <link rel="stylesheet" href="${ctxStatic}/css/common_erp.css">
    <link rel="stylesheet" href="${ctxStatic}/css/layerSm.css"> 
    <script type="text/javascript">
    
    //删除方法
    function delDict(){
          // 调用后台删除方法
        $.post("${ctx}/finance/subject/delete?id=${finance.id}&&oldItemValue=${dict.oldItemValue}",'',function(result){
             // 提示信息
             tipParent(result.message);
             // 返回状态
            if(result.statusCode==STATUSCODEOK){
                 // 刷新页面
                window.parent.frames[0].location.reload();
                 // 关闭页面
                closeWin(); 
             }
        },'json');
   }
   </script>
   
    </head>
	<body>
	<!-- 创建页面head部 -->
	<div id="editPage" class="layerHeader clearfix">
    	<p class="headerTitle"><spring:message code="dict_readAccount"/></p>
			<div class="headerButton clearfix">
	        <!-- 编辑 -->
	        <shiro:hasPermission name="finance:subject:edit">
	        <button type="button" onClick="window.location.href='${ctx}/finance/subject/form?id=${finance.id}'" >
	               <spring:message code="dict_edit" />
	        </button>
	        
            <!-- 删除 -->
            <button type="button" onclick="del(delDict)"><spring:message code="btn_delete"/></button>
            </shiro:hasPermission>
            <!-- 取消 -->
            <button type="button" onclick="closeWin()"><spring:message code="btn_cancle"/></button>          
	    </div>
	</div>
<div id="showHtml">
	<div class="smList">
		<div class="items clearfix">
			<div class="col-50 clearfix">
				<!-- 科目代码 -->
				<p class="tit">
					<spring:message code="account_code"/>
				</p>
				<p>${finance.itemCode}</p>
			</div>
		</div>
	        
		<div class="items clearfix">
			<div class="col-50 clearfix">
				<!-- 科目名称 -->
				<p class="tit">
					<spring:message code="course_title" />
				</p>
				<p>${finance.itemName}</p>
			</div>
			
		</div>
	        
		<div class="items clearfix">
			<div class="col-50 clearfix">
				<!-- 科目类别 -->
				<p class="tit">
					<spring:message code="account_category" />
				</p>
				<p>${fns:getDictName(finance.itemCategory)}</p>
			</div>
		</div>
	        
		<div class="items clearfix">
			<div class="col-50 clearfix">
				<!-- 借贷方 -->
				<p class="tit">
					<spring:message code="reversal_of_entries" />
				</p>
				<p>${fns:getDictName(finance.itemkbn)}</p>
			</div>
		</div>
	        
		<div class="items clearfix">
			<div class="col-50 clearfix">
				<!-- 状态 -->
				<p class="tit"><spring:message code="dict_state_show"/></p>
				<p class="rtname fl">
				<c:choose>
					<c:when test="${finance.enableFlag eq 1}"><spring:message code="dict_enable"/></c:when>
				</c:choose>
				<c:choose>
					<c:when test="${finance.enableFlag eq 0}"><spring:message code="dict_disable"/></c:when>
				</c:choose>
				</p>
			</div>
		</div>
	<div class="items clearfix">
			<div class="col-50 clearfix">
				<!-- 描述 -->
				<p class="tit">
					<spring:message code="dict_remarks_show" />
				</p>
				<p>${finance.remarks}</p>
			</div>
		</div>
	</div>
</div>
</body>
</html>